1. Field of the Invention
The present invention relates to systems and methods for conducting distributed transactions with database servers.
2. Description of the Related Art
A database is a collection of data that is organized so that its contents can be easily accessed, managed, and updated. Currently, the most prevalent type of database is the relational database, which is a tabular database in which data is defined so that it can be reorganized and accessed in a number of different ways. Another type of database is an object-oriented programming database, which is one that is congruent with the data defined in object classes and subclasses. In addition, there is a distributed database, which is one that can be dispersed or replicated among different points in a computer network.
Most databases contain aggregations of data records or files, such as sales transactions, product catalogs and inventories, and customer profiles. Typically, a database manager provides users the capabilities of controlling read/write access, specifying report generation, and analyzing usage. Databases and database managers are prevalent in large mainframe systems, but are also present in smaller distributed workstation and mid-range systems such as the AS/400 and on personal computers.
Distributed transaction processing (TP) systems use multiple databases to conduct distributed transactions. Distributed TP systems are designed to facilitate transactions that span heterogeneous, transaction-aware resources in a distributed environment. An application supported by a distributed TP system can combine into a transactional unit such diverse activities as retrieving a message from a queue, such as a Microsoft® Message Queuing (MSMQ) queue, storing the message in a database, such as Microsoft™ SQL server database, and removing all existing references to the message from a server. Because they span multiple data resources, it is important that distributed transactions maintain data consistency across all resources. A distributed TP system consists of several cooperating entities, which can reside on the same computer or on different computers.
For instance, a TP monitor is software that sits between a transaction-aware application and a collection of resources. The TP monitor maximizes operating system activities, streamlines network communications, and connects multiple clients to multiple applications that potentially access multiple data resources. Instead of writing an application that manages a multi-user, distributed environment, one can write an application that consists of single transaction requests. The monitor scales the application as required. An example is the Distributed Transaction Coordinator (DTC), which is the TP monitor for the existing Microsoft® Windows® environment.
There are also transaction managers. In a distributed transaction, each participating resource has a local transaction manager to track incoming and outgoing transactions on that computer. The TP monitor assigns one transaction manager the additional task of coordinating all activities among local transaction managers. The transaction manager that coordinates transaction activities is called the root or coordinating transaction manager. A coordinating transaction manager coordinates and manages all transaction processing functions, but it is not equipped to manage data directly. Resource managers handle these data-related activities.
In addition, there are resource managers, which are system services that manage persistent or durable data in databases, durable message queues, or transactional file systems. The resource manager stores data and performs disaster recovery.
Moreover, resource dispensers manage non-durable states that can be shared. For example, the Open Database Connectivity (ODBC) resource dispenser manages pools of database connections, reclaiming each connection when it is no longer needed.
Along with the level of data manipulation and processing, the level of database access and usage for conducting transactions has increased dramatically over the years
However, a problem that exists with current technology is that there have not been systems and methods developed to implement certain transaction solutions, such as the Java™ Transaction API (JTA), for standard query language databases, such as the Microsoft® SQL database, because of insufficient network interfaces to support distributed transactions. Thus, there is a need for a new and improved system and method of implementing distributed transactions. For example, in distributed transactions, an XA switch is used to map the XA specification protocol to the database transaction management implementation. In the case of Microsoft's® SQL Server, an XA switch is provided with the SQL Server database management system that maps XA functionality to the corresponding distributed transaction coordinator transaction management facilities. However, for the Java™ Database Connectivity (JDBC™) driver to fully implement JTA, additional functionality is needed in the driver. Currently, the additional functionality does not exist. It was for this reason that a complete JTA solution with increased functionality for the SQL Server was invented as discussed below.